package com.etc.servlet;

import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.UUID;

import javax.servlet.ServletException;
import javax.servlet.annotation.MultipartConfig;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.Part;
@MultipartConfig(location="D:/tmp1", fileSizeThreshold=1024*102,maxFileSize=1024*1024*5, maxRequestSize=1024*1024*5*5)
@WebServlet("/upload1")
public class UploadServlet2 extends HttpServlet{

	@Override
	protected void doPost(HttpServletRequest request, HttpServletResponse resp) throws ServletException, IOException {
		
		request.setCharacterEncoding("UTF-8");
		
        String bast64 = request.getParameter("file");
        AService a = new AService();
        a.aaa(bast64);
        
        System.out.println(bast64);
        resp.getWriter().print("success");
	}

	
}
